Optimal. Leaf size=52 \[ \frac {1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )^2-\frac {2}{9} b n x^3 \left (a+b \log \left (c x^n\right )\right )+\frac {2}{27} b^2 n^2 x^3 \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.04, antiderivative size = 52, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2305, 2304} \[ \frac {1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )^2-\frac {2}{9} b n x^3 \left (a+b \log \left (c x^n\right )\right )+\frac {2}{27} b^2 n^2 x^3 \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2304
Rule 2305
Rubi steps
\begin {align*} \int x^2 \left (a+b \log \left (c x^n\right )\right )^2 \, dx &=\frac {1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )^2-\frac {1}{3} (2 b n) \int x^2 \left (a+b \log \left (c x^n\right )\right ) \, dx\\ &=\frac {2}{27} b^2 n^2 x^3-\frac {2}{9} b n x^3 \left (a+b \log \left (c x^n\right )\right )+\frac {1}{3} x^3 \left (a+b \log \left (c x^n\right )\right )^2\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.02, size = 46, normalized size = 0.88 \[ \frac {1}{3} \left (x^3 \left (a+b \log \left (c x^n\right )\right )^2+\frac {2}{9} b n x^3 \left (-3 a-3 b \log \left (c x^n\right )+b n\right )\right ) \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.42, size = 103, normalized size = 1.98 \[ \frac {1}{3} \, b^{2} n^{2} x^{3} \log \relax (x)^{2} + \frac {1}{3} \, b^{2} x^{3} \log \relax (c)^{2} - \frac {2}{9} \, {\left (b^{2} n - 3 \, a b\right )} x^{3} \log \relax (c) + \frac {1}{27} \, {\left (2 \, b^{2} n^{2} - 6 \, a b n + 9 \, a^{2}\right )} x^{3} + \frac {2}{9} \, {\left (3 \, b^{2} n x^{3} \log \relax (c) - {\left (b^{2} n^{2} - 3 \, a b n\right )} x^{3}\right )} \log \relax (x) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.35, size = 111, normalized size = 2.13 \[ \frac {1}{3} \, b^{2} n^{2} x^{3} \log \relax (x)^{2} - \frac {2}{9} \, b^{2} n^{2} x^{3} \log \relax (x) + \frac {2}{3} \, b^{2} n x^{3} \log \relax (c) \log \relax (x) + \frac {2}{27} \, b^{2} n^{2} x^{3} - \frac {2}{9} \, b^{2} n x^{3} \log \relax (c) + \frac {1}{3} \, b^{2} x^{3} \log \relax (c)^{2} + \frac {2}{3} \, a b n x^{3} \log \relax (x) - \frac {2}{9} \, a b n x^{3} + \frac {2}{3} \, a b x^{3} \log \relax (c) + \frac {1}{3} \, a^{2} x^{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [C] time = 0.21, size = 692, normalized size = 13.31 \[ \frac {b^{2} x^{3} \ln \left (x^{n}\right )^{2}}{3}+\frac {\left (-3 i \pi b \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )+3 i \pi b \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}+3 i \pi b \,\mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}-3 i \pi b \mathrm {csgn}\left (i c \,x^{n}\right )^{3}-2 b n +6 b \ln \relax (c )+6 a \right ) b \,x^{3} \ln \left (x^{n}\right )}{9}+\frac {\left (-9 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right )^{2} \mathrm {csgn}\left (i x^{n}\right )^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{2}+18 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right )^{2} \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{3}+18 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right )^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{3}-36 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{4}+12 i \pi \,b^{2} n \mathrm {csgn}\left (i c \,x^{n}\right )^{3}-36 i \pi \,b^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{3} \ln \relax (c )-36 i \pi a b \mathrm {csgn}\left (i c \,x^{n}\right )^{3}+36 a^{2}-12 i \pi \,b^{2} n \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}-12 i \pi \,b^{2} n \,\mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}+36 i \pi \,b^{2} \mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2} \ln \relax (c )+36 i \pi \,b^{2} \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2} \ln \relax (c )+36 i \pi a b \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}+36 i \pi a b \,\mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{2}+8 b^{2} n^{2}-9 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right )^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{4}+18 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{5}-9 \pi ^{2} b^{2} \mathrm {csgn}\left (i x^{n}\right )^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{4}+18 \pi ^{2} b^{2} \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )^{5}+72 a b \ln \relax (c )-24 b^{2} n \ln \relax (c )+36 b^{2} \ln \relax (c )^{2}-24 a b n -9 \pi ^{2} b^{2} \mathrm {csgn}\left (i c \,x^{n}\right )^{6}-36 i \pi \,b^{2} \mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right ) \ln \relax (c )-36 i \pi a b \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )+12 i \pi \,b^{2} n \,\mathrm {csgn}\left (i c \right ) \mathrm {csgn}\left (i x^{n}\right ) \mathrm {csgn}\left (i c \,x^{n}\right )\right ) x^{3}}{108} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.67, size = 71, normalized size = 1.37 \[ \frac {1}{3} \, b^{2} x^{3} \log \left (c x^{n}\right )^{2} - \frac {2}{9} \, a b n x^{3} + \frac {2}{3} \, a b x^{3} \log \left (c x^{n}\right ) + \frac {1}{3} \, a^{2} x^{3} + \frac {2}{27} \, {\left (n^{2} x^{3} - 3 \, n x^{3} \log \left (c x^{n}\right )\right )} b^{2} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 3.56, size = 62, normalized size = 1.19 \[ x^3\,\left (\frac {a^2}{3}-\frac {2\,a\,b\,n}{9}+\frac {2\,b^2\,n^2}{27}\right )+\frac {x^3\,\ln \left (c\,x^n\right )\,\left (2\,a\,b-\frac {2\,b^2\,n}{3}\right )}{3}+\frac {b^2\,x^3\,{\ln \left (c\,x^n\right )}^2}{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [B] time = 1.52, size = 143, normalized size = 2.75 \[ \frac {a^{2} x^{3}}{3} + \frac {2 a b n x^{3} \log {\relax (x )}}{3} - \frac {2 a b n x^{3}}{9} + \frac {2 a b x^{3} \log {\relax (c )}}{3} + \frac {b^{2} n^{2} x^{3} \log {\relax (x )}^{2}}{3} - \frac {2 b^{2} n^{2} x^{3} \log {\relax (x )}}{9} + \frac {2 b^{2} n^{2} x^{3}}{27} + \frac {2 b^{2} n x^{3} \log {\relax (c )} \log {\relax (x )}}{3} - \frac {2 b^{2} n x^{3} \log {\relax (c )}}{9} + \frac {b^{2} x^{3} \log {\relax (c )}^{2}}{3} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________